* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(159deg, #1d1d2f 0%, #0d0d27 25%, #0f1f2f 75%, #0a2240 100%);
    min-height: 100vh;
    display: flex;
    align-items: center; 
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-y: auto;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(50, 50, 120, 0.05) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(120, 50, 120, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.container {
    max-width: 600px;
    width: 100%;
    text-align: center;
    position: relative;
    z-index: 1;
    padding-bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 40px);
}

/* Custom Alert Styles */
.alert-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.alert-overlay.show {
    opacity: 1;
    visibility: visible;
}

.alert-box {
    background: #1a1a2e;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.3s ease;
}

.alert-overlay.show .alert-box {
    transform: translateY(0);
    opacity: 1;
}

.alert-box p {
    font-size: 16px;
    margin-bottom: 20px;
    line-height: 1.5;
}

.alert-box .alert-ok-btn {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 16px 50px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 140px;
}

.alert-box .alert-ok-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.9);
}

.alert-box .alert-ok-btn:active {
    transform: translateY(1px);
}

.pagination {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 80px;
    gap: 20px;
}

.back-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
}

.page-indicator {
    display: flex;
    gap: 12px;
}

.page-dot {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    font-size: 16px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.page-dot.active {
    background: rgba(255, 255, 255, 0.95);
    color: #1a1a2e;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.2);
}

.page-dot.inactive {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.4);
}

.logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 50px;
    background: transparent;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo img {
    width: 60px;
    height: 60px;
    color: white;
}

h1 {
    color: rgba(255, 255, 255, 0.95);
    font-size: 2.2rem;
    font-weight: 600;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.subtitle {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
    margin-bottom: 60px;
    line-height: 1.6;
    font-weight: 400;
}

.seed-phrase-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 50px;
}

.seed-input-container {
    position: relative;
}

.seed-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 20px 16px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 16px;
    text-align: center;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    font-weight: 400;
}

.seed-input::placeholder {
    color: rgba(255, 255, 255, 0.2);
}

.seed-input:focus {
    outline: none;
    border-color: rgba(76, 110, 245, 0.4);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 0 0 3px rgba(76, 110, 245, 0.08);
}

.seed-input:hover:not(:focus) {
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.025);
}

.word-number {
    position: absolute;
    top: -8px;
    left: 16px;
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.restore-btn {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 16px 50px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 140px;
}

.restore-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.9);
}

.restore-btn:active {
    transform: translateY(1px);
}

.restore-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Footer Divider and Company Info Styles */
.footer-divider {
    width: 80%;
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin: 40px auto 20px;
}

.company-info {
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    line-height: 1.6;
    font-weight: 400;
    text-align: center;
}

.company-info a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

.company-info a:hover {
    color: rgba(255, 255, 255, 0.9);
}

.company-info p {
    margin-bottom: 8px;
}

@media (max-width: 768px) {
    .seed-phrase-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    .pagination {
        margin-bottom: 60px;
    }

    .container {
        padding-bottom: 60px;
    }

    .company-info {
        font-size: 0.85rem;
    }

    .footer-divider {
        width: 90%;
    }
}

@media (max-width: 480px) {
    .seed-phrase-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    
    .pagination {
        margin-bottom: 40px;
    }

    .container {
        padding-bottom: 80px;
    }

    .company-info {
        font-size: 0.8rem;
    }

    .footer-divider {
        width: 95%;
    }
}

.container > * {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.pagination { animation-delay: 0.1s; }
.logo { animation-delay: 0.2s; }
h1 { animation-delay: 0.3s; }
.subtitle { animation-delay: 0.4s; }
.seed-phrase-grid { animation-delay: 0.5s; }
.restore-btn { animation-delay: 0.6s; }
.alert-overlay { animation-delay: 0.7s; }
.footer-divider { animation-delay: 0.75s; }
.company-info { animation-delay: 0.8s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}